package com.salmon.rpc.test;


import com.salmon.rpc.RpcFramework;
import com.salmon.rpc.test.service.HelloService;

public class RpcConsumer {

    public static void main(String[] args) throws Exception {
        HelloService helloService = RpcFramework.refer(HelloService.class, "127.0.0.1", 1234);
        for (int i = 0; i < 100; i++) {
            String result = helloService.hello("world " + i);
            System.out.println("远程调用结果是" + result);
            Thread.sleep(1000);
        }
    }
}
